package com.ruoyi.feign;

import com.ruoyi.common.core.web.domain.AjaxResult;
import com.ruoyi.common.log.annotation.Log;
import com.ruoyi.common.log.enums.BusinessType;
import com.ruoyi.common.security.annotation.RequiresPermissions;
import com.ruoyi.domain.ResidentTask;
import com.ruoyi.fallbackFactory.ResidentTaskFeignClientFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient(value = "ruoyi-resident-task", fallbackFactory = ResidentTaskFeignClientFallbackFactory.class)
public interface ResidentTaskFeignClient {

    @RequiresPermissions("residentTask:residentTask:add")
    @Log(title = "住户核酸任务", businessType = BusinessType.INSERT)
    @PostMapping("/residentTask")
    AjaxResult add(@RequestBody ResidentTask residentTask);
}